package com.example.graphic.AI;

import lombok.Data;

import java.util.List;

/**
 * AI图片生成响应DTO
 */
@Data
public class AIImageGenerateResponse {
    
    /**
     * 生成的图片URL列表
     */
    private List<String> generatedImageUrls;
    
    /**
     * 响应消息
     */
    private String message;
    
    /**
     * 响应状态码
     */
    private Integer code;
    
    /**
     * 是否成功
     */
    private Boolean success;
    
    public AIImageGenerateResponse() {
    }
    
    public AIImageGenerateResponse(List<String> generatedImageUrls, String message) {
        this.generatedImageUrls = generatedImageUrls;
        this.message = message;
        this.success = true;
        this.code = 200;
    }
    
    public static AIImageGenerateResponse success(List<String> generatedImageUrls, String message) {
        return new AIImageGenerateResponse(generatedImageUrls, message);
    }
    
    public static AIImageGenerateResponse error(String message, Integer code) {
        AIImageGenerateResponse response = new AIImageGenerateResponse();
        response.setMessage(message);
        response.setCode(code);
        response.setSuccess(false);
        return response;
    }
}